#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f, maxn = 1000007;
const long long MOD = 1004535809;
const long long LINF = 0x3f3f3f3f3f3f3f3fLL;
const long long P = 19260817;
int n, Q;
struct edge {
  int v, nxt;
} e[maxn << 1];
int sz[maxn];
int son[maxn];
int fa[maxn], dep[maxn];
int top[maxn];
int cnt;
int head[maxn];
void addedge(int u, int v) {
  e[++cnt].v = v;
  e[cnt].nxt = head[u];
  head[u] = cnt;
}
void dfs1(int u, int f) {
  fa[u] = f;
  dep[u] = dep[f] + 1;
  son[u] = 0;
  sz[u] = 1;
  for (int i = head[u]; i; i = e[i].nxt) {
    int v = e[i].v;
    if (v == f) continue;
    dfs1(v, u);
    sz[u] += sz[v];
    if (son[u] == 0 || sz[v] > sz[son[u]]) {
      son[u] = v;
    }
  }
}
void dfs2(int u, int t) {
  top[u] = t;
  if (son[u]) dfs2(son[u], t);
  for (int i = head[u]; i; i = e[i].nxt) {
    int v = e[i].v;
    if (v == fa[u] || v == son[u]) continue;
    dfs2(v, v);
  }
}
int lca(int x, int y) {
  while (top[x] != top[y]) {
    if (dep[top[x]] < dep[top[y]]) swap(x, y);
    x = fa[top[x]];
  }
  return dep[x] < dep[y] ? x : y;
}
int dis(int x, int y) {
  if (x == y) return 0;
  return dep[x] + dep[y] - 2 * dep[lca(x, y)];
}
int d[maxn];
int main() {
  scanf("%d", &n);
  for (int i = 1; i < n; i++) {
    int u, v;
    scanf("%d%d", &u, &v);
    addedge(u, v);
    addedge(v, u);
  }
  dfs1(1, 0);
  dfs2(1, 1);
  scanf("%d", &Q);
  for (int i = 1; i <= Q; i++) {
    int x, y, a, b, k;
    scanf("%d%d%d%d%d", &x, &y, &a, &b, &k);
    int xa = dis(a, x), xb = dis(b, x), ya = dis(a, y), yb = dis(b, y),
        xy = dis(x, y), ab = dis(a, b);
    d[1] = ab;
    d[2] = min(xa + yb, xb + ya) + 1;
    int dr = xy + 1;
    int da = (xa + ya - xy) / 2, db = (xb + yb - xy) / 2;
    d[3] = dr - (d[2] - da - db) + da + db;
    d[4] = d[1] + dr + 2 * min(da, db);
    int f = 0;
    for (int i = 1; i <= 4; i++) {
      if (!f && k >= d[i] && ((d[i] ^ k) & 1) == 0) {
        printf("YES\n");
        f = 1;
      }
    }
    if (!f) puts("NO");
  }
  return 0;
}
